package com.wlsk.license.common.converter;

import com.wlsk.license.common.enums.CharterTypeEnum;

/**
 * 包车牌类型枚举转换器
 */
public class CharterTypeConverter extends BaseEnumConverter<String> {

    @Override
    protected String getDescByCode(String code) {
        if (code == null) {
            return null;
        }
        CharterTypeEnum charterPlateTypeEnum = CharterTypeEnum.get(code);
        if (charterPlateTypeEnum == null) {
            return null;
        }
        return charterPlateTypeEnum.getDescription();
    }

    @Override
    public Class<Integer> supportJavaTypeKey() {
        return Integer.class;
    }
}